package me.zhengjie.pojo.entity;


import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDateTime;

@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("wcs_fluent_frame_config")
public class WcsFluentFrameConfig {

    @TableId(type = IdType.AUTO)
    private Integer id;

    @TableField("unit_id")
    private Integer unitId;

    //区域(A或B)
    @TableField("region")
    private String region;

    //气缸地址位1：对接上层(入库)  2：对接下层（出库）
    @TableField("cylinder")
    private Integer cylinder;

    //出库第一段地址位
    @TableField("outbound_one_address")
    private Integer outboundOneAddress;

    //出库第二段地址位
    @TableField("outbound_two_address")
    private Integer outboundTwoAddress;

    //出库第三段地址位
    @TableField("outbound_three_address")
    private Integer outboundThreeAddress;

    //分拣地址位
    @TableField("sorting_address")
    private Integer sortingAddress;

    //入库第一段地址位
    @TableField("inbound_one_address")
    private Integer inboundOneAddress;

    //入库第二段地址位
    @TableField("inbound_two_address")
    private Integer inboundTwoAddress;

    //入库第三段地址位
    @TableField("inbound_three_address")
    private Integer inboundThreeAddress;

    //储位区域（工位）
    @TableField("storage_region")
    private String storageRegion;

    //出库储位编码
    @TableField("out_storage_code")
    private String outStorageCode;

    //分拣读码信息地址位
    @TableField("sorting_read_address")
    private Integer sortingReadAddress;

    //分拣完成告诉TCP地址位
    //扫码完成告诉TCP地址位
    @TableField("sorting_result_address")
    private Integer sortingResultAddress;

    //出库储位数量地址位
    @TableField("outbound_storage_size_address")
    private Integer outboundStorageSizeAddress;

    //0空箱模式，1正常入库
    @TableField("mode")
    private Integer mode;

    //分拣区容器编码
    @TableField("sorting_container_code")
    private String sortingContainerCode;

    //气缸控制地址位 1：整箱出库,2：分检出库
    @TableField("cylinder_control_address")
    private Integer cylinderControlAddress;

    //单层或双层流利架，1单2双
    @TableField("single_or_double")
    private Integer singleOrDouble;

    //流利架出库数量 单层流利架记录的是AGV出库空箱的数量
    @TableField("size")
    private Integer size;

    //入库第一段读码地址位
    @TableField("one_inb_read_address")
    private Integer oneInbReadAddress;


    //入库第二段读码地址位
    @TableField("two_inb_read_address")
    private Integer twoInbReadAddress;

    //入库第三段读码地址位
    @TableField("three_inb_read_address")
    private Integer threeInbReadAddress;

    //入库请求取货地址位
    @TableField("inb_request_take")
    private Integer inbRequestTake;

    //入库写入PLC(0默认，1发送)
    @TableField("inb_plc_status")
    private Integer inbPlcStatus;

    //出库第一段读码地址位
//    @TableField("one_out_read_address")
//    private Integer oneOutReadAddress;
//
//    //出库第二段读码地址位
//    @TableField("two_out_read_address")
//    private Integer twoOutReadAddress;
//
//    //出库第三段读码地址位
//    @TableField("three_out_read_address")
//    private Integer threeOutReadAddress;

    //出库请求放货地址位
    @TableField("out_request_release")
    private Integer outRequestRelease;

    //入库储位编码
    @TableField("inbound_storage_code")
    private String inboundStorageCode;

    //CTU入库任务反馈（0：无任务；1：任务中，2任务完成）
    @TableField("three_inb_return_result")
    private Integer threeInbReturnResult;

    //CTU入库任务反馈（0：无任务；1：任务中，2任务完成）
    @TableField("three_out_return_result")
    private Integer threeOutReturnResult;

    //写入plc，0表示未写，1表示写入
    @TableField("write_plc")
    private Integer writePlc;

    //工位设备ip
    @TableField("device_ip")
    private String deviceIp;

    //工作站
    @TableField("workstation")
    private String workstation;

    //分拣区储位编码
    @TableField("sorting_storage")
    private String sortingStorage;

    //分拣区读码完成地址位(0：初始状态；1：OK；2：NG）)
    @TableField("sorting_reading_finish")
    private Integer sortingReadingFinish;

    //出库plc是否允许放货，0初始，1允许
//    @TableField("out_plc_release_goods")
//    private Integer outPlcReleaseGoods;
//
//    //出库回报plc，0默认，1任务中，2任务完成
//    @TableField("out_plc_reply")
//    private Integer outPlcReply;

    //回库请求往前流
    @TableField("return_to_warehouse")
    private Integer returnToWarehouse;

    //回库读码状态
    @TableField("return_reading")
    private Integer returnReading;

    //回库读码
    @TableField("return_reading_code")
    private Integer returnReadingCode;

    //方向
    @TableField("direction")
    private String direction;

    //ctu取货时间
    @TableField("ctu_take_time")
    private LocalDateTime ctuTakeTime;

    @TableField("sweep_storage")
    private String sweepStorage;

    @TableField("inb_agv_eqpt_code")
    private String inbAgvEqptCode;

    @TableField("out_agv_eqpt_code")
    private String outAgvEqptCode;
}
